Programming device

ABSTRACT

A programming device of a programmable status control system is provided for converting a control function to a control program for an automation device. The programming device with a graphic programming interface is suitable for programming a programmable status control system.

FIELD OF THE INVENTION

The present invention relates to a programming device of a programmablestatus control system.

BACKGROUND INFORMATION

German Patent Application No. 37 43 438 describes a device that causes atransition to a subsequent status and a transfer of new control data toan output stage according to an instantaneous status and an input vectorallocation of digital process input quantities. A control data file,which contains the input quantities or combinations of these inputquantities that are relevant for the given instantaneous status, isstored in the device.

German Patent Application No. 42 26 456 describes a programmable statuscontrol system that permits a transition in status from an instantaneousstatus to a subsequent status for several processors.

With such conventional status control system and the conventionaldevice, reaction times to changes in input data are shortenedsignificantly in comparison with a conventional programmable controlsystem that gradually reads individual control program instructions outof a memory in accordance with processing by a von Neumann machine,interprets them and finally executes the corresponding operations.

The publication "Automation with SIMATIC S5-155U" by Hans Berger (1989)describes a programming device that is used to convert a control taskinto a control program for an automation device. All functions of thecontrol task are programmed or described with a type of presentationsuch as an "instruction list," a "function plan" or a "contact plan."Regardless of the type of presentation, the programming device convertsthe programmed functions to an appropriate machine code. This codecontains all the user-programmed control functions and is read andinterpreted by the automation device after the code has been transferredto the automation device. With such a conventional programming device,writing a control program for a programmable status control systemrequires considerable programming effort. German Patent Application No.42 35 432 discloses a programming device for a programmable statuscontrol system. The programming device has a memory where a control taskcreated with a software tool is deposited in the form of an action-timediagram that can be displayed on a display device and describes theinput and output signals of an engineering process to be controlled inthe form of binary and/or analog signals. The action-time diagram isprocessed by the software tool by means of suitable analysis of leveltransitions of the signals to create a control program having a controland status code to solve the control task, starting from aninstantaneous status, and appropriate input codes, control codes andstatus codes of the control program are created for the status controlsystem. It is not necessary to know a programming language or the typesof presentation conventionally used in automation technology for acontrol task.

German Patent Application No. 44 18 623 describes a programming devicesuitable for programming a programmable status control system with astructured text. The structured text is divided into severalsubstructures, each of which is assigned to a status. Each substructurehas a first key word with a string of characters that denote a statusand is followed by at least one group of ordered pairs consisting of akey word and a text string. A first pair has a second key word and atleast one input vector in the form of a string of characters followed bya second pair consisting of a third key word and a subsequent status inthe form of another string of characters. If necessary to solve thecontrol task, the substructures must have a third and fourth pair, thethird of which is provided with a fourth key word and at least oneoutput vector in the form of a string of characters, and the fourth pairincludes a fifth key word and at least one function referencecharacterized by a string of characters. Such a structured text is easyto formulate and permits a straightforward presentation of the controltask.

SUMMARY OF THE INVENTION

An object of the present invention is to provide a programming devicewith a graphic programming interface suitable for programming aprogrammable status control system.

Using such device, a programmer formulates a control task in the form ofa status graph that has symbols for the statuses and for the input andoutput transitions. From these symbols the software tool generates astructured text (as described in German Patent Application No. 44 18 623from which a suitable software tool in the form of a compiler and linkercreates a control table executable in the status control system.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows a schematic diagram of a system controlled by aprogrammable status control system.

FIG. 2 shows a status graph.

FIG. 3 shows a structured text.

FIG. 4 shows a first table for an assignment of input and outputsignals, function references and input and output transitions.

FIG. 5 shows a second table for the assignment of input and outputsignals, function references and input and output transitions.

FIG. 6 shows a third table for the assignment of input and outputsignals, function references and input and output transitions.

FIG. 7 shows a fourth table for the assignment of input and outputsignals, function references and input and output transitions.

FIG. 8 shows a fifth table for the assignment of input and outputsignals, function references and input and output transitions.

FIG. 9 shows a control program for the programmable status controlsystem

DETAILED DESCRIPTION OF THE INVENTION

FIG. 1 shows a programmable status control system 9 that controls areactor 1 on the basis of input signals E0.0, E0.1 and E0.2. Inputsignal E0.0 indicates that a reactor cycle has been started by apush-button 4, and input signals E0.1, E0.2 generated by sensors 2, 3indicate that the reactor is full or empty, respectively. Output signalA0.0 is sent to an alarm lamp 8 and indicates the start of the reactorcycle. Output signals A0.1, A0.3 are sent to valves 5, 6 to control theinflow and outflow of a reactor fluid, and output signal A0.2 causesreactor 1 to be heated by heating system 7.

A control task now stipulates that a reactor cycle is to be started bypush-button 4 and displayed by alarm lamp 8. For example 600 ms afterthe start, inlet valve 5 of empty reactor 1 is to be opened but outletvalve 6 must be closed during a filling operation. Furthermore, thecontrol task specifies that inlet valve 5 must remain closed if thereactor is full and that heat is to be supplied to the liquid in reactor1 via heating system 7 for a period of e.g. five minutes. Then areaction time of e.g. three minutes is provided during which the liquidreacts to the heat supplied. When the three minutes have elapsed, thereactor is emptied. Inlet valve 5 remains closed and outlet valve 6 isopened for this purpose. When reactor 1 is empty, alarm lamp 8 isswitched off after a recovery time of e.g. 30 seconds, thus indicatingthat the reactor cycle is completed and a new cycle can be started.

A programmer with a programming device not shown here converts thecontrol task formulated in this way to a status graph (shown in FIG. 2).The programming device equipped with a display device and a memory has asoftware tool deposited in the memory for this purpose and also hasinstructions and commands for representing the status graph on thedisplay device. The software tool also converts this status graph to astructured text according to FIG. 3. Reference is made first to FIG. 9to explain how further processing takes place. FIG. 9 shows a controlprogram in the form of a control table that can also be represented onthe display device and generates another software tool from thestructured text as explained below. It is also possible to provide onlya software tool suitable for creating the status graph, converting thestatus graph to a structured text and creating a control table from thestructured text. For a better overview, the control table is subdividedinto blocks 1a . . . 1g, each of which is assigned to a status Z0 . . .Z6 and stored in appropriate areas of the memory. Z0 . . . Z6 denote thecodes for the statuses "dormant," "start of process,""filling,""heating," "reaction," "emptying" and "end of process"; e_(ij)denotes the input vector assignments formed from the binary values ofthe input signals E0.0 . . . and internal signals Ti, T2 of the statuscontrol system 9, and S_(ij) denotes the control data vector assignmentsformed from the binary values of input signals A0.0 . . . and functioncodes F0 . . . F6, where I=0, 1 . . . 6; j=0, 1. The character x denotesthat the binary value of an input signal E0.0 . . . assigned to thischaracter is irrelevant, i.e., the corresponding input and control datavector is formed independently of the binary value of this input signal.The character X in the control data vector assignment means that thebinary values of the output signals A0.0 . . . remain unchanged with thecorresponding input vector assignments.

In this embodiment of the present invention, a status graph with symbolsfor statuses and input and output transitions is shown (FIG. 2). Thestatus symbols are characterized by rounded rectangles ZS1 . . . ZS7 andstrings of characters assigned to them ("dormant,""start of process,","filling (the reactor)," "heating (the reactor liquid)," "emptying (thereactor)" and "end of process."The starting status is the "dormant"status which is symbolized by a double border. Symbols Tr1 . . . Tr7 forthe input transitions are shown between the status symbols ZS1 . . .ZS7. In the present example, only one directional line leads from astatus to an input transition, which results from the requirements ofthe control task. It is of course possible for solving complex controltasks to require a status graph containing a directional line thatbranches off from a status symbol and ends in several input transitionsymbols. A line leads from the "dormant" starting status to an inputtransition Trn with a "start" string of characters from which anotherdirectional line leads to the subsequent "start of process"status andanother directional line leads to action symbol A1. The "start" stringof characters designates an input vector whose bit assignment isdiscussed in greater detail below. According to the stipulations of thecontrol program, additional input transitions with the assigned stringsof characters "begin filling," "begin heating," . . . "stop" are shownas symbols in the form of rectangles Tr2, Tr3 . . . Tr7. Starting from astatus symbol ZS1 . . . ZS7, a directional line leads to thesetransitions Tr1 . . . Tr7 from each of which a directional line againleads to a status symbol and a directional line leads to the actionsymbol A1 . . . A7 according to the stipulations of the control program.These symbols A1 . . . A7 have strings of characters written into themto describe output quantities as well as function references, asdiscussed further below. Action symbol A1 contains an output quantity inthe form of the string of characters "lamp₋₋ on, " action symbol A2contains the output quantity "inlet₋₋ open," action symbol A3 containsthe output quantity "heating₋₋ on," action symbol A4 contains the outputquantity "heating₋₋ off" action symbol A5 contains the output quantity"outlet₋₋ open," action symbol A6 contains the output quantity "outlet₋₋closed" and action symbol A7 contains the output quantity "lamp₋₋ off."As additional output quantities, action symbols A1, A3, A4, A6 and A7represent function references FAA, FAC, FAD and FAF which stipulate theprocess times of the control task according to time-limit switchsettings of status control system 9 (shown in FIG. 1), as explainedbelow. These form internal binary input signals Ti, T2 that control theheating and reaction time as well as the delay times with regard to theopening of inlet valve 5 and turning off lamp 8 according to therequirements described in the control task.

Further processing of the status graph (shown in FIG. 2) for creation ofa structured text (shown in FIG. 3) by the software tool is explained ingreater detail below.

The software tool creates from the seven status symbols ZS1 . . . ZS7 astructured text with seven substructures A . . . G (shown in FIG. 3),each of which is assigned to a status. The statuses are deposited in theform of character strings in header information KI and include thestatuses "start of process," "filling (the reactor)," "heating (thereactor liquid)," "emptying (the reactor)" and "end of process"accordingto the designations (character strings) of the status symbols. The"dormant" status is marked as the initial status on the status graph andis also stored in the header information. The software tool creates fromthe instantaneous "dormant" status symbol (shown in FIG. 2) a first keyword SWA1 (substructure A, FIG. 3) in the form of the "status"characterstring to which a "dormant" string of characters designating aninstantaneous status is assigned. The software tool forms a group ofordered pairs, each consisting of a key word and a character string,from input transition symbol Tr1 and the "start" character stringassigned to this symbol, the action symbol A1 and the "lamp₋₋ on"character string assigned to this symbol and also from the symbol ZS2 ofthe subsequent status and the "start of process" string of characters. Afirst pair of this group includes a second key word SWA2 ("IF"characterstring) and an input vector EVA in the form of a "start" characterstring. A second pair follows this input vector EVA and is provided witha third key word SWA3 ("THEN"string) and with a subsequent status FZAcharacterized by a "start of process" character string. A third pairfollowing the subsequent status FZA includes a fourth key word SWA4("SET" string) and an output vector AVA in the form of a "lamp₋₋ on"string. The software tool forms a fourth pair with a fifth key word SWA5("DO" string) and the function reference FAA ("F11" string) from thefunction reference FAA. This fourth pair follows output vector AVA.

Substructures B . . . G are formulated in the same way as defined by thestatus graphs, where SWxy (x=B, C, . . . G; y=1, 2, . . .) denotes thefirst, second, etc. key words, EVk and AVk denote the input and outputvectors, FZk denotes the subsequent statuses and FAk(k=B, C, . . . G)denotes the function references of substructures B, C, . . . G. Thesoftware tool takes into account the fact that no fifth key word and nofunction reference are needed for substructures B, E and G because noentries in the form of function references are made in the correspondingaction symbols A2, A5 and A7.

In the present example, no information is provided in the status graphsregarding the assignments of the input and output vectors or those ofthe input and output signals, so in order to convert the structured textto a control table (shown in FIG. 9) these assignments must also bestipulated according to the definitions of the control task. It isstipulated that a depressed start key 4 (shown in FIG. 1) be representedby binary value 1 (input signal E0.0=1). Accordingly, E0.1=1 means "thereactor is full" and E0.2=1 means "the reactor is empty"(shown in FIG.4). Furthermore, the assignment of output signals is defined as A0.0=1if lamp 8 is turned on, A0.1=1 if inlet 5 is open (or is to be opened),A0.2=1 if heating 7 is switched on and A0.3=1 if outlet valve 6 is openor is to be opened (shown in FIG. 5). Furthermore, as already describeabove, function references in the form of strings of characters F00 . .. F66 which stipulate the process times of the control task according tothe time limit switch settings of status control system 9 (FIG. 1) arealso relevant as additional output quantities in the present example.FIGS. 6 and 7 show the assignment of internal input signals T1, T2 andthe function references in the form of character strings F00 . . . F66.

On the basis of this definition in the assignment tables in FIGS. 4 to 7and the definitions of the control task, the programmer thus knows whichassignments (levels) of input and output signals E0.0, E0.1, E0.2, andA0.0, A0.1, A0.2 are relevant and which subsequent statuses must bereached in applying the relevant input signals, starting from aninstantaneous status, and which output signals must be output next tosolve the control task. According to this information, input and outputvectors EVk and AVk (k=A, B, . . . G) are assigned according to FIG. 8and finally substructures A . . . G are formulated according to FIG. 3.

The assignment tables according to FIGS. 4 to 8 can of course be omittedif instead of the character strings "start,""begin filling," . . . ;"lamp₋₋ on," "inlet₋₋ open," . . . the input and output signals areentered for the input and output vectors EVk, AVk, and the assignmentsshown in FIGS. 4 to 8 for the function references (FAk, . . . ) areentered directly in the symbols of the statuses ZS1, . . . ZS7, theinput and output transitions Tr1, . . . Tr7; A1, . . . A7. This has theadvantage that the control table shown in to FIG. 9 can be generateddirectly from the status graph using the software tool. For a betteroverview of the program, however, it is advantageous to enter only thecorresponding character strings and to formulate the assignments in aseparate list according to FIGS. 4 to 8. It is also possible to enterjust some of the assignments in the symbols of the status graphs, e.g.,the output bits according to FIG. 5 in action symbols A1, . . . A7, butthe remaining assignments are entered in the assignment lists accordingto FIGS. 7 and 8 that are provided for this purpose. The characterstrings ("start,""filling," . . . ) of these transitions provided forthis purpose are entered in the symbols of the corresponding transitionsTR1, . . . Tr7 in this case.

Once the conversion of the control task in the form of the writtenstructured text is concluded, the software tool generates the controltable shown in FIG. 9. To do so, the software tool first generates thecorresponding instantaneous status in coded form Z0 (shown in FIG. 9,area 1a) from the first key word SWAL and the first character"dormant"string of substructure A, and finally the input vectorassignment in coded is generated form as e01=(10100) from the firstordered pair consisting of the second key word SWA2 ("IF"string) and theinput vector EVA ("start" string), taking into account the assignment ofthe "start" string (shown in FIG. 8), the binary value definition of theinput signals and the internal input signals (shown in FIGS. 4 and 6).On the basis of the second pair consisting of the third key word SWA3("THEN" string) and the "start of process" string, the software toolcreates the code Z1 of the subsequent status. The software toolgenerates the code for the control data vector assignment asS01=(1000F1) (where F1 denotes a function code formed from characterstring F11) from the fourth key word SWA4 ("SET"string) and outputvector AVA ("lamp" string) and from the fifth key word SWA5 ("DO"string) and function reference FAA ("F11" string), taking into accountthe assignment of the "lamp₋₋ on" string (shown in FIG. 8), the F11string (shown in FIG. 7) and the binary value definition of the outputsignals (shown in FIG. 5), where F1 represents a function code formedfrom the F11 string. Thus the coding (compiling) of substructure A ofthe structured text is concluded with regard to a change in status fromthe instantaneous "dormant" status to a subsequent "start of process"status for the case when the assignment is in the form 10100 (=e01) (seearea 1a, FIG. 9). There are no other character strings in substructureA, which means that no change of status is provided for all otherpossible assignments of the input vector, and the software toolautomatically creates another code line in area 1a of the control table,namely input vector assignment e00 and a control data vector assignmentS00 which are assigned to a subsequent status code Z0 corresponding tothe instantaneous status.

In control operation of the programmable status control system, the codelines written in area 1a of the control table cause a change to thesubsequent "start of process" status (code Z1) starting from theinstantaneous "dormant" status (code Z0) only if the real vector formedfrom the currently pending input signals E0.0, E0.1, E0.2 and theinternal signals T1, T2 of status control system 9 (shown in FIG. 1)have the assignment (10100), i.e., it corresponds to the preset inputvector assignment e01. In addition, control data vector S01=(1000F1) isoutput only for this case. The control system remains in theinstantaneous status "dormant" (represented by the "otherwise" string inFIG. 9) for all other current input signals.

In the same manner described here, the software tool generates codelines in areas 1b . . . 1g of the control table from substructures B . .. G. However, substructures B, E and G each lack a fifth key word SW5kand a function reference FAk (k=B, E, G). Therefore, software toolgenerates a function code F0 for control data vector assignments S11,S41 and S61. This code is of no relevance during control operation ofthe status control system and does not form any function reference thattriggers functions.

The control table thus generated is transferred to the programmablestatus control system that solves the control task described in GermanPatent Application Nos. 42 26 456 and 37 43 438 according to therequirements of this table. The transfer can be accomplished by havingthe control table read out of the memory of the programming device,written to a diskette or a memory module and transferred from there tothe user memory of the status control system. The transfer can of coursealso be accomplished on line via a suitable connection of theprogramming device to the status control system. The software tool ispreferably designed so that it is possible to generate the structuredtext from a given control table and conversely it is also possible togenerate the respective status graph from the structured text, becauseall information in the structured text is reversibly and unambiguouslyreflected in the control table and all information in the status graphis reversibly and unambiguously reflected in the structured text.

I claim:
 1. A programming device of a programmable status controlsystem, comprising:a controller for executing a software tool togenerate a control task; and a memory apparatus for storing the controltask as a status graph which is displayable by a display device andwhich includes symbols corresponding to statuses, input transitions andoutput transitions, wherein the controller executing the software toolgenerates from the status graph a structured text having a plurality ofsubstructures, and wherein the controller executing the software toolgenerates:a first key word and a first character string from a statussymbol of the symbols corresponding to the statuses and from acorresponding character string assigned to the status symbol, a secondkey word following the first character string and a second characterstring following the second key word from at least one transition symbolof the input transition and from a fifth character string assigned tothe at least one transition symbol, so that the second character stringcorresponds to an input vector, a third key word following the secondcharacter string and a third character string following the third keyword from the status symbol of subsequent statuses and from a sixthcharacter string assigned to the at least one transition symbol, so thatthe third character string corresponds to the status symbol of thesubsequent statuses, and a fourth key word following the third characterstring and a fourth character string following the fourth key word froman action symbol of an output transition and from a seventh characterstring assigned to the action symbol, so that the fourth characterstring corresponds to an output vector.
 2. The programming deviceaccording to claim 1, wherein the controller executing the software toolfurther generates a fifth key word following the fourth character stringand a function reference following the fifth key word from the fourthcharacter string assigned to the action symbol.
 3. The programmingdevice according to claim 1, wherein the symbols are linked withdirectional lines, the directional lines including a first line startingfrom the status symbol and leading to the at least one transitionsymbol, a second line starting from the at least one transition symboland leading to the status symbol, and a third line starting from the atleast one transition symbol and leading to the action symbol.
 4. Theprogramming device according to claim 1, wherein the symbols can have adifferent representation on the display device.
 5. The programmingdevice according to claim 1, wherein the controller executing thesoftware tool further generates a control table operable in the statuscontrol system from the key words and from the character strings toprovide:an instantaneous status in a coded form from the first key wordand from the first character string, an input vector assignment in thecoded form from the third key word and the third character string, and acontrol data vector assignment in the coded form from the fourth keyword and the fourth character string.
 6. The programming deviceaccording to claim 2, wherein the software tool supplements a controldata vector assignment with a function code assigned to the functionreference from the fifth key word and the function reference.
 7. Theprogramming device according to claim 1, wherein the structured text canbe converted back to the status graph.